﻿// HSS.Interlink.Web.Response.cs
// ----------------------------------------------------------------------------
// Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.html)
// ----------------------------------------------------------------------------
// HighSpeed-Solutions, LLC
// Copyright (c) 2001-2012
// ----------------------------------------------------------------------------
// File:       Response.cs
// Author:     HSS\gbanta
// Created:    07/16/2011
// Modified:   07/22/2011
// ----------------------------------------------------------------------------
namespace HSS.Interlink.Web
{
	#region Using Directives

	#endregion

	#region Responses
	/// <summary>
	/// Contains the ResponseCommands
	/// </summary>
	internal static class Responses
	{
		/// <summary>
		/// Gets the response string from the Resource Manager.
		/// </summary>
		/// <param name="response"></param>
		/// <returns></returns>
		public static string GetResponse(Response response)
		{
			if (response == Response.Success)
				return string.Empty;
			return Properties.Resources.ResourceManager.GetString(response.ToString());
		}
	}
	/// <summary>
	/// The Interlink Command Responses.
	/// </summary>
	public enum Response
	{
		/// <summary>
		/// Success or empty string response
		/// </summary>
		Success,
		/// <summary>
		/// file-already-exists
		/// </summary>
		FileAlreadyExists,
		/// <summary>
		/// file-does-not-exist
		/// </summary>
		FileDoesNotExist,
		/// <summary>
		/// Unauthorized request
		/// </summary>
		UnauthorizedRequest,
		/// <summary>
		/// Unknown exception
		/// </summary>
		UnknownException,
		/// <summary>
		/// Unknown request
		/// </summary>
		UnknownRequest,
		/// <summary>
		/// Retry the last chunk (only availble for Upload request's AppendFile method.
		/// </summary>
		AppendFileRetry,
		/// <summary>
		/// Errors encountered, please try again or contact your administrator
		/// </summary>
		FatalError
	}
	#endregion
}